<?php
/* -------------------------------------------------------------------------------------
* 	ID:						$Id: settings.php 11 2013-09-21 11:43:11Z phone.mueller@googlemail.com $
* 	Letzter Stand:			$Revision: 11 $
* 	zuletzt geaendert von:	$Author: siekiera $
* 	Datum:					$Date: 2013-09-21 11:43:11 +0000 (Sat, 21 Sep 2013) $
*
* 	SEO:mercari by Siekiera Media
* 	http://www.seo-mercari.de
*
* 	Copyright © since 2011 SEO:mercari
* --------------------------------------------------------------------------------------
* 	based on:
* 	© 2000-2001 The Exchange Project  (earlier name of osCommerce)
* 	© 2002-2003 osCommerce - www.oscommerce.com
* 	© 2003     nextcommerce - www.nextcommerce.org
* 	© 2005     xt:Commerce - www.xt-commerce.com
*
* 	Released under the GNU General Public License
* ----------------------------------------------------------------------------------- */

echo draw_form('slider', 'slider.php', 'save=settings&'.getMenuID('slider'), 'POST', 'id="slider"');
	$settings = $db->db_query("SELECT 
									configuration_key, configuration_value, set_function 
								FROM
									".TABLE_SLIDER_SETTINGS);
	echo '<table width="100%" cellpadding="5">';
	while(!$settings->EOF) { $i++;
		if(!empty($settings->fields['set_function']))
			eval('$value_field = '.$settings->fields['set_function'].'"'.htmlspecialchars($settings->fields['configuration_value']).'");');
		else
			$value_field = draw_input_field($settings->fields['configuration_key'], $settings->fields['configuration_value']);

		if(strstr($value_field, 'configuration_value'))
			$value_field = str_replace('configuration_value', $settings->fields['configuration_key'], $value_field);

		if ($i % 2 == 0)
			$f = '';
		else
			$f = 'dataTableRow';
		echo '	<tr class="'.$f.'" >
					<td width="30%" valign="top" style="border-top: 1px solid #ccc">
						<b>'.constant(strtoupper($settings->fields['configuration_key'].'_TITLE')).'</b>
					</td>
					<td valign="top" align="left" style="border-top: 1px solid #ccc">
						<table width="100%"  border="0" cellspacing="0" cellpadding="2">
							<tr>
								<td>'.$value_field.'</td>
							</tr>
						</table>
						<p>'.constant(strtoupper($settings->fields['configuration_key'].'_DESC')).'</p>
					</td>
				</tr>';
		$settings->MoveNext();
	}
	echo '</table>';
?>
</form>